<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>login</title>
<link rel="stylesheet" type="text/css" href="../css/themes/default/easyui.css" />
<link rel="stylesheet" type="text/css" href="../css/themes/icon.css" />
<link rel="stylesheet" type="text/css" href="../css/style_01.css" />
<script type="text/javascript" src="../js/jquery-1.7.2.js"></script>
<script type="text/javascript" src="../js/easyui/jquery.easyui.min.js"></script>
<%
	String loginName = request.getParameter("loginName");
	if (null == loginName) {
		loginName = "";
	}
	String loginPWD = request.getParameter("loginPWD");
	if (null == loginPWD) {
		loginPWD = "";
	}
	String msg = request.getParameter("msga");
	if (null == msg) {
		msg = "";
	}
%>
<script type="text/javascript">
	if (window.top != window) {
		window.top.location.reload();
	}

	$(function() {
		document.loginForm.loginName.focus();

		$("#button_ok").click(function() {
			document.loginForm.submit();
		})
	})
	function login(event) {
		if (event.keyCode != 13) {
			return;
		}
		if ($.trim($('#loginName').val()) == '') {
			$('#error').html('请输入用户名!');
			document.loginForm.userName.focus();
			return;
		}
		if ($.trim($('#loginPWD').val()) == '') {
			$('#error').html('请输入密码!');
			document.loginForm.userPWD.focus();
			return;
		}
		$.post("../member/login", {}, function(str) {
		});
		document.loginForm.submit();
	}
</script>
</head>
<body>
	<div style="width: 100%; height: 100%; text-align: center;">
		<div style="width: 300px; height: 180px; MARGIN-RIGHT: auto; MARGIN-LEFT: auto; margin-top: 200px;">
			<div class="easyui-panel">
				<form id="loginForm" name="loginForm" action="../member/login" method="POST">
					<p>
						用户名称: <input type="text" name="loginName" id="loginName" onkeyup="login(event)" value="<%=loginName%>">
					</p>
					<p>
						用户密码: <input type="password" name="loginPWD" id="loginPWD" onkeyup="login(event)" value="<%=loginPWD%>">
					</p>
					<p>
						<span class="e2_type"><%=msg%></span>
					</p>
					<div style="padding: 2px;">
						<a href="#" class="easyui-linkbutton" data-options="iconCls:'icon-ok'" id="button_ok"></a> <a href="#" class="easyui-linkbutton" data-options="iconCls:'icon-cancel'" id="button_cancel"></a>
					</div>
					<label id="error"></label>
				</form>
			</div>
		</div>
	</div>
</body>
</html>